package com.xiu.eureka.provider.node1.rpc;

import org.springframework.cloud.netflix.feign.FeignClient;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;

/**
 * @Author: Mr.xiu
 * @Description:
 * @Date: 2020/10/28 16:44
 */
@FeignClient(name = "ipServer",url = "https://api.ip.sb/")
public interface IpFeign {

  /**
   * 获取对应的IP
   * @param ip  Ip
   * @return 结果
   */
  @RequestMapping(value = "/geoip/{ip}", method = RequestMethod.GET)
  Object ipInfo(@PathVariable("ip") String ip);
}
